/*
 * Copyright (c) 2017. 深圳一七网络有限公司. All rights reserved.
 */

package com.yiqi.zhiyuan.framework.api;


import com.suozhang.framework.entity.bo.Result;
import com.yiqi.zhiyuan.entity.dto.LocationDTO;
import com.yiqi.zhiyuan.entity.dto.TaskDTO;
import com.yiqi.zhiyuan.entity.vo.CarVO;
import com.yiqi.zhiyuan.entity.vo.HomeVO;
import com.yiqi.zhiyuan.entity.vo.OrderVO;

import java.util.List;

import io.reactivex.Observable;
import retrofit2.http.Body;
import retrofit2.http.GET;
import retrofit2.http.POST;
import retrofit2.http.Path;

/**
 * @ProjectName: ZhiYuan
 * @Package: com.yiqi.zhiyuan.feature.login.view
 * @ClassName: UserInformationActivity
 * @Description: 首页相关API
 * @Author:
 * @CreateDate: 2019/3/11 17:45
 * @UpdateUser: 更新者
 * @UpdateDate: 2019/3/11 17:45
 * @UpdateRemark: 更新说明
 * @Version: 1.0
 */
public interface HomeApi {

    /**
     * 首页获取司机数据
     *
     * @param
     */
    @POST("api/driver/selectDriverHomeInfo")
    Observable<Result<HomeVO>> selectDriverHomeInfo();

    /**
     * 首页获取司机汽车数据
     *
     * @param
     */
    @POST("api/driver/selectDriverCarList")
    Observable<Result<List<CarVO>>> selectDriverCarList();
    /**
     * 司机接单快捷设置
     * */

    @GET("api/driver/orderQuickSetup/{carDriverId}/{type}")
    Observable<Result<String>> orderQuickSetup(@Path("carDriverId") Integer carDriverId,@Path("type") int type );
    /**
     * 抢单
     * */

    @POST("api/driver/orders")
    Observable<Result<OrderVO>> order(@Body TaskDTO taskDTO);

    /**
     * 立即前往
     * */

    @POST("api/driver/goNow")
    Observable<Result<OrderVO>> arriveAtLocation(@Body TaskDTO taskDTO);

    /**
     * 查询未接订单列表
     * */
    @POST("api/driver/selectMissedOrderList")
    Observable<Result<List<OrderVO>>> selectMissedOrderList(@Body LocationDTO locationDTO);

}
